<%@ page contentType="text/html; charset=utf-8" language="java" %>
<%
String deptId=(String)request.getParameter("deptId");
String deptName=(String)request.getParameter("deptName");
deptName=java.net.URLDecoder.decode(deptName,"utf-8");
deptName=new String(deptName.getBytes("ISO-8859-1"),"utf-8");
%>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>人力资源管理系统</title>
<link rel="stylesheet" rev="stylesheet" href="../css/style.css " type="text/css" media="all" />
<script type="text/javascript" src="../Js/typem.js"></script>
<script type="text/javascript" src="../Js/js.js"></script>
<style type="text/css">
<!--
.atten {font-size:12px;font-weight:normal;color:#F00;}
-->
</style>
<script type="text/javascript">
function openwin()
{
var id,name;
str =window.showModalDialog("job.do?method=list&number="+Math.random(),window,"dialogWidth=800px;dialogHeight=400px");
//window.alert(str);
if(str.indexOf("-")>=0){
  id=str.substring(0,str.indexOf("-"));
  name=str.substring(str.indexOf("-")+1,str.length);
}
//window.alert(id);
document.getElementById("superiorId").value=id;
document.getElementById("superiorName").value=name;
}
</script>
</head>
<body class="ContentBody">
<%
String status=(String)request.getParameter("status");
if(status!=null&&status.equals("success")){
out.print("<script>alert('添加成功！')</script>");
}
 %>
<form name="positionForm" method="post" action="job.do?method=add">
<div class="MainDiv">
<table width="99%" border="0" cellpadding="0" cellspacing="0" class="CContent">
  <tr>
      <th class="tablestyle_title" >职位信息录入</th>
  </tr>
  <tr>
    <td height="261" class="CPanel">
		
		<table width="90%" border="0" cellpadding="0" cellspacing="0" style="width:80%" align="center">
		<tr><td align="left">
		<input type="submit"value="保存" class="button"/>　
			
			<input type="reset" value="返回" class="button"/>
		</td></tr>
		
		<TR>
			<TD width="100%" height="355">
				<fieldset style="height:100%;">
				<legend>职位信息</legend>
				<table width="100%" border="0" cellpadding="2" cellspacing="1" style="width:100%">
					<tr>
						<td nowrap align="right" width="9%">职位名称：</td>
						<td width="36%">
						<input name="name" type="text" class="input" id="name"/>
						<span class="red">*</span></td>
				   		<td nowrap align="right" width="9%">所属部门：</td>
				   		<td width="43%"><input name="deptId" type="hidden" class="input" id="deptId" value="<%=deptId%>"/>
						<input name="deptName" type="text" class="input" id="deptName" value="<%=deptName%>"/>
						<span class="red">*</span></td>                        
					</tr>
					<tr>
						<td nowrap align="right" width="9%">直属上级：</td>
						<td>
						<input name="superiorId" type="hidden" class="input" id="superiorId"/>
						<input name="superiorName" type="text" class="input" id="superiorName" onclick="openwin()"/>
						<span class="red">*</span></td>
						<td nowrap align="right" width="9%">规划人数：</td>
						<td><input name="plannum" type="text" class="input" id="plannum"/>
						<span class="red">*</span></td>
					</tr>
					<tr>
						<td nowrap align="right" width="9%">在职人数：</td>
						<td>
						<input name="occunum" type="text" class="input" id="occunum"/>
						<span class="red">*</span></td>
						<td>&nbsp;</td>
						<td>&nbsp;</td>
					</tr>
					<tr>
						<td nowrap align="right">职位目的：</td>
						<td colspan="3">
						<textarea name="purpose" cols="100" rows="3" class="input" id="purpose"></textarea></td>
					</tr>
					<tr>
						<td nowrap align="right">工作内容：</td>
						<td colspan="3">
						<textarea name="content" cols="100" rows="6" class="input" id="content"></textarea></td>
					</tr>
					<tr>
						<td nowrap align="right">工作职责：</td>
						<td colspan="3">
						<textarea name="duty" cols="100" rows="6" class="input" id="duty"></textarea></td>
					</tr>
				</table>
			 		 <br/>
				</fieldset>
			  </TD>
			
		</TR>
		</TABLE>
	 </td>
  </tr>
		<TR>
			<TD colspan="2" align="center" height="50px">
			<input name="提交" type="submit" class="button" value="保存"/>　
			
			<input name="重置" type="reset" class="button" value="重置"/></TD>
		</TR>
		</TABLE>
</div>
</form>
</body>
</html>

